package com.ruoyi.bearing.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.bearing.mapper.ComponentConditionsMapper;
import com.ruoyi.bearing.domain.ComponentConditions;
import com.ruoyi.bearing.service.IComponentConditionsService;

/**
 * 元器件工况管理Service业务层处理
 * 
 * @author lyz
 * @date 2025-03-31
 */
@Service
public class ComponentConditionsServiceImpl implements IComponentConditionsService 
{
    @Autowired
    private ComponentConditionsMapper componentConditionsMapper;

    /**
     * 查询元器件工况管理
     * 
     * @param conditionId 元器件工况管理主键
     * @return 元器件工况管理
     */
    @Override
    public ComponentConditions selectComponentConditionsByConditionId(Long conditionId)
    {
        return componentConditionsMapper.selectComponentConditionsByConditionId(conditionId);
    }

    /**
     * 查询元器件工况管理列表
     * 
     * @param componentConditions 元器件工况管理
     * @return 元器件工况管理
     */
    @Override
    public List<ComponentConditions> selectComponentConditionsList(ComponentConditions componentConditions)
    {
        return componentConditionsMapper.selectComponentConditionsList(componentConditions);
    }

    /**
     * 新增元器件工况管理
     * 
     * @param componentConditions 元器件工况管理
     * @return 结果
     */
    @Override
    public int insertComponentConditions(ComponentConditions componentConditions)
    {
        return componentConditionsMapper.insertComponentConditions(componentConditions);
    }

    /**
     * 修改元器件工况管理
     * 
     * @param componentConditions 元器件工况管理
     * @return 结果
     */
    @Override
    public int updateComponentConditions(ComponentConditions componentConditions)
    {
        return componentConditionsMapper.updateComponentConditions(componentConditions);
    }

    /**
     * 批量删除元器件工况管理
     * 
     * @param conditionIds 需要删除的元器件工况管理主键
     * @return 结果
     */
    @Override
    public int deleteComponentConditionsByConditionIds(Long[] conditionIds)
    {
        return componentConditionsMapper.deleteComponentConditionsByConditionIds(conditionIds);
    }

    /**
     * 删除元器件工况管理信息
     * 
     * @param conditionId 元器件工况管理主键
     * @return 结果
     */
    @Override
    public int deleteComponentConditionsByConditionId(Long conditionId)
    {
        return componentConditionsMapper.deleteComponentConditionsByConditionId(conditionId);
    }
}
